/*
 * @Author: weikang
 * @Description:
 * @Date: 2023-12-22 11:22:19
 * @LastEditTime: 2023-12-23 17:43:12
 * @FilePath: \env-manager-pc\src\router\modules\assets.ts
 */
import type { RouteRecordRaw } from 'vue-router'

function Layout() {
  return import('@/layouts/index.vue')
}

const routes: RouteRecordRaw = {
  path: '/assets',
  component: Layout,
  redirect: '/assets/order',
  name: 'assets',
  meta: {
    title: '资产管理',
    icon: 'ep:wallet',
  },
  children: [
    {
      path: 'order',
      name: 'assets-order',
      component: () => import('@/views/assets/order/index.vue'),
      meta: {
        title: '订单管理',
        auth: '/assets/order',
      },
    },
    {
      path: 'statistics',
      name: 'assets-statistics',
      component: () => import('@/views/assets/statistics/index.vue'),
      meta: {
        title: '资产统计',
        auth: '/assets/statistics',
      },
    },
    {
      path: 'warehouse',
      name: 'assets-warehouse',
      component: () => import('@/views/assets/warehouse/index.vue'),
      meta: {
        title: '入库管理',
        auth: '/assets/warehouse',
      },
    },
    {
      path: 'get',
      name: 'assets-get',
      component: () => import('@/views/assets/get/index.vue'),
      meta: {
        title: '领用管理',
        auth: '/assets/get',
      },
    },
    {
      path: 'install',
      name: 'assets-install',
      component: () => import('@/views/assets/install/index.vue'),
      meta: {
        title: '安装管理',
        auth: '/assets/install',
      },
    },
    {
      path: 'sales',
      name: 'assets-sales',
      component: () => import('@/views/assets/sales/index.vue'),
      meta: {
        title: '销售管理',
        auth: '/assets/sales',
      },
    },
    {
      path: 'demolish',
      name: 'assets-demolish',
      component: () => import('@/views/assets/demolish/index.vue'),
      meta: {
        title: '拆除管理',
        auth: '/assets/demolish',
      },
    },
  ],
}

export default routes
